﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace KingerRobot.PCRBW.Dao;

partial class Db : K8.EF.DbContext
{
    /// <summary>
    ///钢圈出库订单信息，bak_mes_out_order
    /// </summary>
    public DbSet<BakMesOutOrder> BakMesOutOrders { get; set; }
}
/// <summary>
/// 钢圈出库指令信息
/// </summary>
[Table("bak_mes_out_order")]
public class BakMesOutOrder
{
    /// <summary>
    /// 主键 订单号
    /// </summary>
    [Key]
    [Column("order_id")]
    public string OrderId { get; set; }

    /// <summary>
    ///  1：1号龙门
    /// </summary>
    [Column("gantry_no")]
    public int? GantryNo { get; set; }
    /// <summary>
    /// 订单类型  1：MES订单    2：人工订单
    /// </summary>
    [Column("order_type")]
    public int? OrderType { get; set; }
    /// <summary>
    /// 物料编码
    /// </summary>
    [Column("part_number")]
    public string PartNumber { get; set; }
    /// <summary>
    /// 等级
    /// </summary>
    [Column("out_grade")]
    public string Grade { get; set; }
    /// <summary>
    /// 请求数量
    /// </summary>
    [Column("require_count")]
    public decimal? RequireCount { get; set; }
    /// <summary>
    /// 任务数量
    /// </summary>
    [Column("act_count")]
    public decimal? ActionCount { get; set; }
    /// <summary>
    /// 已发数量
    /// </summary>
    [Column("ship_count")]
    public decimal? ShipCount { get; set; }
    /// <summary>
    /// 0：数据新增；1移库执行中;2移库完成;3出库执行中;4出库完成;5桁架执行中;6桁架任务完成;7异常出库完成
    /// </summary>
    [Column("out_status")]
    public int? Status { get; set; }
    /// <summary>
    /// 终止标志（Y:已终止，N:未终止）
    /// </summary>
    [Column("stop_flag")]
    public string StopFlag { get; set; }
    /// <summary>
    /// 异常标志
    /// </summary>
    [Column("err_flag")]
    public string ErrorFlag { get; set; }
    /// <summary>
    /// 备注
    /// </summary>
    [Column("remarks")]
    public string Remarks { get; set; }
    /// <summary>
    /// 批次号码，默认值0
    /// </summary>
    [Column("batch_name")]
    public string BatchName { get; set; }
    /// <summary>
    /// 物料组
    /// </summary>
    [Column("part_class")]
    public string PartClass { get; set; }
    /// <summary>
    /// 到目的机台
    /// </summary>
    [Column("target_equip")]
    public string TargetEquip { get; set; }
    /// <summary>
    /// 创建时间
    /// </summary>
    [Column("create_time")]
    public DateTime? CreateTime { get; set; }
    /// <summary>
    /// 更新时间
    /// </summary>
    [Column("update_time")]
    public DateTime? UpdateTime { get; set; }
    /// <summary>
    /// 创建人员
    /// </summary>
    [Column("create_user")]
    public string CreateUser { get; set; }
    /// <summary>
    /// 更新人
    /// </summary>
    [Column("update_user")]
    public string UpdateUser { get; set; }
    /// <summary>
    /// 更新标志 1:新增  2:删除 0;复位
    /// </summary>
    [Column("update_flag")]
    public int? UpdateFlag { get; set; }
    /// <summary>
    /// 同步结果，若有错误则写入此字段，成功为空
    /// </summary>
    [Column("error_info")]
    public string ErrorInfo { get; set; }
    /// <summary>
    /// 成型物料编号
    /// </summary>
    [Column("mpart_number")]
    public string MPartNumber { get; set; }
    /// <summary>
    /// 成型物料版本
    /// </summary>
    [Column("mpart_revision")]
    public string MPartRevision { get; set; }
    /// <summary>
    /// 追踪号
    /// </summary>
    [Column("trace_code")]
    public string TraceCode { get; set; }
    /// <summary>
    /// 要料区域
    /// </summary>
    [Column("area_name")]
    public string AreaName { get; set; }
    /// <summary>
    ///0：出库；1：强制出库；2：异常出库
    /// </summary>
    [Column("out_mark")]
    public int? Mark { get; set; }
    /// <summary>
    /// 订单循环  0新增  1新订单判断是否需要移库判断完成  2移库完成订单修改订单状态完成 
    /// </summary>
    [Column("order_circle")]
    public int? OrderCircle { get; set; }
    /// <summary>
    /// 订单绑定的出库物料ID
    /// </summary>
    [Column("out_product_Id")]
    public string OutProductId { get; set; }
    /// <summary>
    /// 起始货位
    /// </summary>
    [Column("start_loc")]
    public long? StartLoc { get; set; }
    /// <summary>
    /// 目标机台
    /// </summary>
    [Column("target_loc")]
    public long? TargetLoc { get; set; }


}